package com.shisfish.library.Impl;

import java.util.List;

import org.springframework.context.ApplicationContext;

import com.shisfish.library.Inter.IRecommendInter;
import com.shisfish.library.Model.Recommend;
import com.shisfish.library.Utils.Global.GetACXmlUtils;

public class RecommendImpl implements IRecommendInter {

	private ApplicationContext ac = GetACXmlUtils.getACXml();
	private IRecommendInter mapper = (IRecommendInter) ac.getBean("recommendMapper");
	
	@Override
	public int insertOne(Recommend t) {
		// TODO Auto-generated method stub
		return mapper.insertOne(t);
	}

	@Override
	public int insertAll(List<Recommend> list) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int updateOne(Recommend t) {
		// TODO Auto-generated method stub
		return mapper.updateOne(t);
	}

	@Override
	public int updateAll(List<Recommend> list) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public List<Recommend> selectById(int id) {
		// TODO Auto-generated method stub
		return mapper.selectById(id);
	}

	@Override
	public List<Recommend> selectByKey(String key) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public int countAll() {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public List<Recommend> selectAll() {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public int deleteOneById(int id) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int deleteAllById(List<?> ids) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int deleteOneByKey(String key) {
		// TODO Auto-generated method stub
		return 0;
	}

	@Override
	public int deleteAllByKey(List<?> keys) {
		// TODO Auto-generated method stub
		return 0;
	}

	public int countType(int type) {
		// TODO Auto-generated method stub
		return mapper.countType(type);
	}

	public List<Recommend> selectTypePage(int type, int currentPage, int pageSize) {
		// TODO Auto-generated method stub
		return mapper.selectTypePage(type, currentPage, pageSize);
	}

	public int countTypeE(String employee, int type) {
		// TODO Auto-generated method stub
		return mapper.countTypeE(employee, type);
	}

	public List<Recommend> selectTypePageE(String employee, int type,
			int currentPage, int pageSize) {
		// TODO Auto-generated method stub
		return mapper.selectTypePageE(employee, type,
				currentPage, pageSize);
	}

}
